<!DOCTYPE html>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<link href="${pageContext.request.contextPath}/layui/css/layui.css" rel="stylesheet"media="all"/>
<link href="${pageContext.request.contextPath}/css/index.css" rel="stylesheet"/>
<div class="zdy_nav layui-row" style="background: linear-gradient(to bottom, rgba(0,0,0,0.7) 0%,rgba(0,0,0,0) 100%)!important;">
    <div class="content_item">
        <ul class="layui-nav">
            <li class="layui-nav-item"><a href="${pageContext.request.contextPath}/index.do">首页</a></li>
            <li class="layui-nav-item hidden-xs">
                <a href="${pageContext.request.contextPath}/ds.do?category=tv">电视剧</a>
            </li>
            <li class="layui-nav-item hidden-xs">
                <a href="${pageContext.request.contextPath}/ds.do?category=dy">电影</a>
            </li>
            <li class="layui-nav-item hidden-xs">
                <a href="${pageContext.request.contextPath}/ds.do?category=dm">动漫</a>
            </li>
            <li class="layui-nav-item hidden-xs">
                <a href="${pageContext.request.contextPath}/zy2_category.do?category=国产剧">国产剧</a>
            </li>
            <li class="layui-nav-item hidden-xs">
                <a href="${pageContext.request.contextPath}/zy2_category.do?category=综艺">综艺</a>
            </li>
            <li class="layui-nav-item" class="dd_hiden">
                <a href="javascript:;" onclick="hidden_dd()">更多</a>
                <dl class="layui-nav-child dd_nav">
                    <dd><a class="dd_1" href="${pageContext.request.contextPath}/ds.do?category=tv">剧集</a></dd>
                    <dd><a class="dd_1" href="${pageContext.request.contextPath}/ds.do?category=dy">电影</a></dd>
                    <dd><a class="dd_1" href="${pageContext.request.contextPath}/ds.do?category=dm">动漫</a></dd>
                    <dd><a class="dd_1" href="javascript:;" onclick="alert_1('敬请期待')">美剧</a></dd>
                    <dd><a class="dd_1" href="javascript:;" onclick="alert_1('敬请期待')">韩剧</a></dd>
                   <%-- <dd><a class="dd_1" href="javascript:;" onclick="alert_1('整改中')">伦理片</a></dd>--%>
                    <%--<dd><a class="dd_1" href="${pageContext.request.contextPath}/v_yun2.do">伦理片</a></dd>--%>
                    <dd><a class="dd_1" href="javascript:;" onclick="alert_1('app还在优化哦,过几天上线')">APP</a></dd>
                    <div class="layui-input-inline search_input2">
                        <span style="font-size: 14px; margin-left: 2px">库一【推荐】</span><input type="radio" name="zy2" checked="true" style="color: #C4C6C9;height: 14px;width: 14px;" value="1"/>
                        <span style="font-size: 14px;">库二 </span><input type="radio" name="zy2" style="color: #C4C6C9;height: 14px;width: 14px;"  value="2" />
                    </div>
                </dl>
            </li>
            <div class="layui-icon layui-icon-search zdy_search">
            </div>
                <div class="layui-input-inline search_input">
                    <input type="search" name="title"  id="video_name" class="layui-input video_name1" style="color: black">
                    <input type="hidden" value="${pageContext.request.contextPath}" id="title_url">
                </div>
                <button class="layui-btn search_input submit">搜索</button>
                <div class="layui-input-inline search_input">
                    <span style="font-size: 14px;color: #C4C6C9;">库一【推荐】</span><input type="radio" name="zy" checked="true" style="color: #C4C6C9;height: 14px;width: 14px;" value="1"/>
                    <span style="font-size: 14px;color: #C4C6C9;">库二 </span><input type="radio" name="zy" style="color: #C4C6C9;height: 14px;width: 14px;"  value="2" />
                </div>
        </ul>
        <div class="min_search">
            <input type="search" class="video_name2" style="float: left" placeholder="请输入关键词..."/>
            <i class="layui-icon layui-icon-search i_1 submit2" style="color: white;"></i>
            <i class="layui-icon layui-icon-close i_2"></i>
        </div>
    </div>
</div>

<script>
    var layer;
    $(function () {
        layui.use(['element','layer'], function(){
            layer = layui.layer;
            layui.element;

        });
    })
    function alert_1(i){
       // alert(i);
        layer.alert(i);
    }
$(".submit").click(function () {
    var video_name=$(".video_name1").val();
    if (video_name.trim()==""){
        return;
    }
    var title_url=$("#title_url").val();
    var zyk = $('input[name="zy"]:checked').val();
    if(zyk=="1"){
        window.location.href =title_url+"v_zy2_2.do?title="+video_name;
    }
   else if (zyk=="2"){
        window.location.href =title_url+"findVideo2.do?title="+video_name;
    }
   else{
        window.location.href =title_url+"v_zy2_2.do?title="+video_name;
    }
});
    $(".video_name2").bind('search', function () {
        var video_name=$(".video_name2").val();
        if (video_name.trim()==""){
            return;
        }
        var title_url=$("#title_url").val();
        var zyk = $('input[name="zy2"]:checked').val();
        if(zyk=="1"){
            window.location.href =title_url+"v_zy2_2.do?title="+video_name;
        }
        else if (zyk=="2"){
            window.location.href =title_url+"findVideo2.do?title="+video_name;
        }
        else{
            window.location.href =title_url+"v_zy2_2.do?title="+video_name;
        }
    });
    $(".submit2").click(function () {
        var video_name=$(".video_name2").val();
        if (video_name.trim()==""){
            return;
        }
        var title_url=$("#title_url").val();
        var zyk = $('input[name="zy"]:checked').val();
        if(zyk=="1"){
            window.location.href =title_url+"v_zy2_2.do?title="+video_name;
        }
        else if (zyk=="2"){
            window.location.href =title_url+"findVideo2.do?title="+video_name;
        }
        else{
            window.location.href =title_url+"v_zy2_2.do?title="+video_name;
        }
    });
    $(".zdy_search").click(function () {
        $(".layui-nav").css("display","none");
        $(".min_search").css("display","block");
    })
    $(".i_2").click(function () {
        $(".layui-nav").css("display","block");
        $(".min_search").css("display","none");

    });
    function hidden_dd() {
        $(".dd_hiden").click(function () {
            $(".dd_nav").toggle();
        })
    }
</script>
